﻿using AnesSystem.Models;
using AnesSystem.Services;
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace AnesSystem.ViewModels
{
    class ConfigPrescriptionTypesDataGridViewModel : BaseViewModel<ConfigPrescriptionTypesDataGridViewModel>
    {
        #region Variables

        private ObservableCollection<ConfigPrescriptionTypesModel> _configPrescriptionTypesModel = new ObservableCollection<ConfigPrescriptionTypesModel>();

        #endregion

        #region Constructor

        public ConfigPrescriptionTypesDataGridViewModel()
        {
            initConfigPrescriptionTypesModel();
        }

        #endregion

        #region Properties

        public ObservableCollection<ConfigPrescriptionTypesModel> ConfigPrescriptionTypesModel
        {
            get
            {
                return _configPrescriptionTypesModel;
            }

            set
            {
                _configPrescriptionTypesModel = value;
                RaisePropertyChanged("ConfigPrescriptionTypesModel");
            }
        }

        #endregion

        #region Event

        #endregion

        #region Private Methods
        private void initConfigPrescriptionTypesModel()
        {
            IEnumerable<ConfigPrescriptionTypesModel> list = ConfigPrescriptionTypesModelService.Instance.FindAll();
            foreach (var item in list)
            {
                _configPrescriptionTypesModel.Add(item);
                
            }
        }

      
        #endregion

        #region Public/Protected Methods


        #endregion

        #region EventHandlers

        #endregion

        #region Command

        #region ChangeDoctorCommand

        #endregion

        #region OpenPopupCommand

        #endregion
        #endregion


    }
}
